MPEG-2 is now the most widely accepted standard for the transmission and/or storage of compressed digital video signals. More particularly, the MPEG-2 standard specifies a syntax (i.e., bitstream format) for a compressed digital video stream and a semantic (decoder algorithm) for decoding the MPEG-2 bitstream. The MPEG-2standard leaves to the individual user the design of an encoder system which encodes an uncompressed digital video stream to generate a compressed MPEG-2 bitstream.
The video signal which is input into an MPEG-2 encoding system comprises a sequence of frames. The frames may be progressive or interlaced. An interlaced frame picture comprises odd and even field pictures.
FIG. 1 schematically illustrates the format of one type of video stream which is inputted into a video encoder system. More specifically, FIG. 1 illustrates the CCIR 656 (or D1) format. Each frame comprises four successive regions, namely (1) odd blanking region, (2) odd active region, (3) even blanking region, and (4) even active region. The blanking regions contain lines in the vertical blanking interval and the active regions contain lines in the active video interval of the CCIR 656 or D1 formats. The number of pixels per line will vary depending on specific encoding features.
In general, an MPEG-2 encoder system includes a preprocessor and an encoder. The preprocessor performs a variety of functions to place the sequence of video frames into a format in which the frames can be compressed by the encoder. For example, in the case where the video source is a telecine machine which outputs 30 interlaced frames per second, the preprocessor converts the signal into 24 frames per second for compression in the encoder by detecting and eliminating duplicate fields produced by the telecine machine. In addition, the preprocessor may spatially scale each picture of the source video so that it has a format which meets the parameter ranges specified by the encoder.
The video encoder is preferably an encoder which utilizes a video compression algorithm to provide an MPEG-2 compatible bit stream. The MPEG-2 bit stream has six layers of syntax. There are a sequence layer (random access unit, context), Group of Pictures layer (random access unit, video coding), picture layer (primary coding layer), slice layer (resychronization unit), macroblock layer (motion compensation unit), and block layer (DCT unit). A group of pictures (GOP) is a set of frames which starts with an I-picture and includes a certain number of P and B pictures. The number of pictures in a GOP may be fixed. A slice is a group of consecutive 16.times.16 macroblocks.
The first step in a real time encoder system is capturing an incoming digital video stream. The capturing of the incoming digital video stream constitutes an important link between the encoder system and the outside environment. In general, the video stream is the main point upon which all of the encoding system's modules are synchronized. As the incoming video stream is not immune to noise and other types of corruption, in the event of a bad video stream, the encoder system must be able to continue its function and more importantly resynchronize its internal modules with the video stream once the video stream has regained coherency.
A corrupt video signal can be divided into two main categories: the first category is one where the video signal's synchronization points are still detectable, but are not coming at the expected times. This abnormality is mostly due to the presence of noise on the input signal, or the incoherency of the video source itself.
The second major problem category is when the video signal is completely lost, where the encoder has lost its reference to the video stream and must operate without a major synchronization point. This case normally occurs when the video source is disconnected from the encoder system. It may also occur in some video storage formats where during the rewind of video the synchronization signals become unavailable. In both cases of corrupt video streams, however, the encoding system must be able to continue its functionality, and be able to resynchronize itself to the video once the input video stream has stabilized.
It is an object of the invention to provide a synchronization method for a video encoding system which enables the encoding system to resynchronize itself to a video input stream once the video input stream has stabilized following a corruption event.